-- GENERATED SPELL FOR [Gordunni Shaman] --


function spell0_5236(pUnit, Event) --@Fire Nova Totem,Self--
if charge_disp ~= 'na' then
pUnit:FullCastSpellOnTarget(8499,pUnit)
local charge_disp = 'na'
end
pUnit:RegisterEvent('Sorts_5236', 1, 1)
end

function spell1_5236(pUnit, Event) --@Healing Wave,Heal--
pUnit:FullCastSpellOnTarget(8005,pUnit)
pUnit:RegisterEvent('Sorts_5236', 3000, 1)
end

function spell2_5236(pUnit, Event) --@Lightning Shield,Self--
pUnit:FullCastSpellOnTarget(8134,pUnit)
pUnit:RegisterEvent('Sorts_5236', 629, 1)
end

function Sorts_5236(pUnit, Event)
local choix_sorts_5236 = math.random(0, 2)
if choix_sorts_5236 == 0 then
pUnit:RegisterEvent('spell0_5236', 1, 1)
end
if choix_sorts_5236 == 1 then
pUnit:RegisterEvent('spell1_5236', 1, 1)
end
if choix_sorts_5236 == 2 then
pUnit:RegisterEvent('spell2_5236', 1, 1)
end
end

function mob5236_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_5236', math.random(1500, 3000), 1)
end

function mob5236_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob5236_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob5236_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(5236, 1, 'mob5236_Action')
RegisterUnitEvent(5236, 2, 'mob5236_Leave')
RegisterUnitEvent(5236, 3, 'mob5236_Kill')
RegisterUnitEvent(5236, 4, 'mob5236_Die')
